GATE CSE 2018


Q41.

Consider Guwahati (G) and Delhi (D) whose temperatures can be classified as high (G), medium (M) and low (L). Let P(H_{G}) denote the probability that Guwahati has high temperature. Similarly, P(M_{G}) and P(L_{G} ) denotes the probability of Guwahati having medium and low temperatures respectively. Similarly, we use P(H_{D}),P(M_{D}) and P(L_{D}) for Delhi. The following table gives the conditional probabilities for Delhi's temperature given Guwahati's temperature. Consider the first row in the table above. The first entry denotes that if Guwahati has high temperature (H_{G}) then the probability of Delhi also having a high temperature (H_{D}) is 0.40; i.e., (H_{D}|H_{G}) = 0.40. Similarly, the next two entries are P(M_{D}| H_{G})= 0.48 and P(L_{D}|H_{G}) = 0.12. Similarly for the other rows. If it is known that P(H_{G})= 0.2, P(M_{G})= 0.5, andP(L_{G})= 0.3, then the probability (correct to two decimal places) that Guwahati has high temperature given that Delhi has high temperature is _______
GateOverflow

Q42.

Two people, P and Q, decide to independently roll two identical dice, each with 6 faces, numbered 1 to 6. The person with the lower number wins. In case of a tie, they roll the dice repeatedly until there is no tie. Define a trial as a throw of the dice by P and Q. Assume that all 6 numbers on each dice are equi-probable and that all trials are independent. The probability (rounded to 3 decimal places) that one of them wins on the third trial is
GateOverflow

Q43.

Consider the following solution to the producer-consumer synchronization problem. The shared buffer size is N. Three semaphores empty, full and mutex are defined with respective initial values of 0, N and 1. Semaphore empty denotes the number of available slots in the buffer, for the consumer to read from. Semaphore full denotes the number of available slots in the buffer, for the producer to write to. The placeholder variables, denoted by P, Q, R, and S, in the code below can be assigned either empty or full. The valid semaphore operations are: wait() and signal(). Which one of the following assignments to P, Q, R and S will yield the correct solution?
GateOverflow

Q44.

Consider an IP packet with a length of 4,500 bytes that includes a 20-byte IPv4 header and a 40-byte TCP header. The packet is forwarded to an IPv4 router that supports a Maximum Transmission Unit (MTU) of 600 bytes. Assume that the length of the IP header in all the outgoing fragments of this packet is 20 bytes. Assume that the fragmentation offset value stored in the first fragment is 0. The fragmentation offset value stored in the third fragment is _______.
GateOverflow

Q45.

Consider the first-order logic sentence \varphi \equiv \exists s\exists t\exists u\forall v\forall w\forall x\forall y\varphi (s,t,u,v,w,x,y) where \varphi (s,t,u,v,w,x,y) is a quantifier-free first-order logic formula using only predicate symbols, and possibly equality, but no function symbols. Suppose \varphi has a model with a universe containing 7 elements. Which one of the following statements is necessarily true?
GateOverflow

Q46.

A queue is implemented using a non-circular singly linked list. The queue has a head pointer and a tail pointer, as shown in the figure. Let n denote the number of nodes in the queue. Let enqueue be implemented by inserting a new node at the head, and dequeue be implemented by deletion of a node from the tail. Which one of the following is the time complexity of the most time-efficient implementation of enqueue and dequeue, respectively, for this data structure?
GateOverflow

Q47.

The set of all recursively enumerable languages is
GateOverflow

Q48.

Consider the relations r(A, B) and s(B, C), where s.B is a primary key and r.B is a foreign key referencing s.B. Consider the query Q:r \Join (\sigma _{B\lt 5}(s)) Let LOJ denote the natural left outer-join operation. Assume that r and s contain no null values. Which one of the following queries is NOT equivalent to Q?
GateOverflow

Q49.

Let N be the set of natural numbers. Consider the following sets. P: Set of Rational numbers (positive and negative) Q: Set of functions from {0, 1} to N R: Set of functions from N to {0, 1} S: Set of finite subsets of N. Which of the sets above are countable?
GateOverflow

Q50.

Which one of the following statements is FALSE?
GateOverflow